/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * AddTurma.java
 *
 * Created on 28/07/2011, 12:07:22
 */

package controlenotas;

/**
 *
 * @author jeferson
 */
public class AddTurma extends javax.swing.JDialog {

    /** Creates new form AddTurma */
    public AddTurma(java.awt.Frame parent, boolean modal) {
        super(parent, modal);
        initComponents();
        this.setSize(350, 245);
        this.setLocationRelativeTo(parent);
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel1 = new javax.swing.JLabel();
        jXPanel1 = new org.jdesktop.swingx.JXPanel();
        jSeparator2 = new javax.swing.JSeparator();
        jXPanel3 = new org.jdesktop.swingx.JXPanel();
        jXPanel4 = new org.jdesktop.swingx.JXPanel();
        jSpinner1 = new javax.swing.JSpinner();
        jXPanel5 = new org.jdesktop.swingx.JXPanel();
        jTextField2 = new javax.swing.JTextField();
        jSeparator1 = new javax.swing.JSeparator();
        jXPanel2 = new org.jdesktop.swingx.JXPanel();
        jButton1 = new javax.swing.JButton();
        jButton2 = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("Adicionar Turmas");
        setResizable(false);

        jLabel1.setBackground(java.awt.Color.white);
        jLabel1.setFont(new java.awt.Font("Ubuntu", 1, 24)); // NOI18N
        jLabel1.setForeground(java.awt.SystemColor.activeCaption);
        jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/resources/class_32.png"))); // NOI18N
        jLabel1.setText("Adicionar Turma");
        jLabel1.setOpaque(true);
        jLabel1.setPreferredSize(new java.awt.Dimension(178, 80));
        getContentPane().add(jLabel1, java.awt.BorderLayout.NORTH);

        jXPanel1.setLayout(new javax.swing.BoxLayout(jXPanel1, javax.swing.BoxLayout.PAGE_AXIS));
        jXPanel1.add(jSeparator2);

        jXPanel3.setPreferredSize(new java.awt.Dimension(400, 50));
        jXPanel3.setLayout(new javax.swing.BoxLayout(jXPanel3, javax.swing.BoxLayout.LINE_AXIS));

        jXPanel4.setBorder(javax.swing.BorderFactory.createTitledBorder("Série"));
        jXPanel4.setPreferredSize(new java.awt.Dimension(40, 102));
        jXPanel4.setLayout(new java.awt.BorderLayout());

        jSpinner1.setModel(new javax.swing.SpinnerNumberModel(1, 1, 9, 1));
        jSpinner1.setPreferredSize(new java.awt.Dimension(30, 28));
        jXPanel4.add(jSpinner1, java.awt.BorderLayout.CENTER);

        jXPanel3.add(jXPanel4);

        jXPanel5.setBorder(javax.swing.BorderFactory.createTitledBorder("Turma"));
        jXPanel5.setPreferredSize(new java.awt.Dimension(100, 107));
        jXPanel5.setLayout(new java.awt.BorderLayout());

        jTextField2.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
        jXPanel5.add(jTextField2, java.awt.BorderLayout.CENTER);

        jXPanel3.add(jXPanel5);

        jXPanel1.add(jXPanel3);
        jXPanel1.add(jSeparator1);

        getContentPane().add(jXPanel1, java.awt.BorderLayout.CENTER);

        jXPanel2.setPreferredSize(new java.awt.Dimension(400, 60));

        jButton1.setText("Cancelar");

        jButton2.setText("Ok");

        javax.swing.GroupLayout jXPanel2Layout = new javax.swing.GroupLayout(jXPanel2);
        jXPanel2.setLayout(jXPanel2Layout);
        jXPanel2Layout.setHorizontalGroup(
            jXPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jXPanel2Layout.createSequentialGroup()
                .addContainerGap(122, Short.MAX_VALUE)
                .addComponent(jButton2, javax.swing.GroupLayout.PREFERRED_SIZE, 77, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jButton1)
                .addContainerGap())
        );
        jXPanel2Layout.setVerticalGroup(
            jXPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jXPanel2Layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jXPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jButton1)
                    .addComponent(jButton2))
                .addContainerGap(18, Short.MAX_VALUE))
        );

        getContentPane().add(jXPanel2, java.awt.BorderLayout.PAGE_END);

        pack();
    }// </editor-fold>//GEN-END:initComponents

    /**
    * @param args the command line arguments
    */
    public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                AddTurma dialog = new AddTurma(new javax.swing.JFrame(), true);
                dialog.addWindowListener(new java.awt.event.WindowAdapter() {
                    public void windowClosing(java.awt.event.WindowEvent e) {
                        System.exit(0);
                    }
                });
                dialog.setVisible(true);
            }
        });
    }

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton jButton1;
    private javax.swing.JButton jButton2;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JSeparator jSeparator2;
    private javax.swing.JSpinner jSpinner1;
    private javax.swing.JTextField jTextField2;
    private org.jdesktop.swingx.JXPanel jXPanel1;
    private org.jdesktop.swingx.JXPanel jXPanel2;
    private org.jdesktop.swingx.JXPanel jXPanel3;
    private org.jdesktop.swingx.JXPanel jXPanel4;
    private org.jdesktop.swingx.JXPanel jXPanel5;
    // End of variables declaration//GEN-END:variables

}
